package com.cssy.xxkj.logic.dao;

import java.util.List;
import java.util.Map;

import org.springframework.dao.DataAccessException;

import com.cssy.xxkj.logic.entity.LogicWarehouseInventoryDO;
import com.cssy.xxkj.logic.entity.vo.LogicMaterialBackBillTypeSelVO;
import com.cssy.xxkj.logic.entity.vo.LogicWarehouseEndMonthSumVO;
import com.cssy.xxkj.logic.entity.vo.LogicWarehouseInventoryVO;
import com.plat.exception.SyBaseException;
import com.plat.helper.SearchConditions;

/**
 * 数据访问对象接口
 * @since 2014-09-16
 */
public interface LogicWarehouseInventoryDAO extends LogicBizDAO<LogicWarehouseInventoryDO>{

    /**
     * 插入数据
     * @param logicWarehouseInventoryDO
     * @return 插入数据的主键
     */
    public String insertLogicWarehouseInventoryDO(LogicWarehouseInventoryDO logicWarehouseInventoryDO);

    /**
     * 统计记录数
     * @param logicWarehouseInventoryDO
     * @return 查出的记录数
     */
    public Integer countLogicWarehouseInventoryDOByExample(LogicWarehouseInventoryDO logicWarehouseInventoryDO);

    /**
     * 更新记录
     * @param logicWarehouseInventoryDO
     * @return 受影响的行数
     */
    public Integer updateLogicWarehouseInventoryDO(LogicWarehouseInventoryDO logicWarehouseInventoryDO);

    /**
     * 获取对象列表
     * @param logicWarehouseInventoryDO
     * @return 对象列表
     */
    public List<LogicWarehouseInventoryDO> findListByExample(LogicWarehouseInventoryDO logicWarehouseInventoryDO);

    /**
     * 根据主键获取logicWarehouseInventoryDO
     * @param id
     * @return logicWarehouseInventoryDO
     */
    public LogicWarehouseInventoryDO findLogicWarehouseInventoryDOByPrimaryKey(String id);

    /**
     * 删除记录
     * @param id
     * @return 受影响的行数
     */
    public Integer deleteLogicWarehouseInventoryDOByPrimaryKey(String id);

    /**
     * 多表联合查询用于库存列表
     * @param 
     * @return List<LogicWhAffstockVO>
     */
    public List<LogicWarehouseInventoryVO> findForWareHouseStock(SearchConditions scs) throws DataAccessException;
    
    /**
     * 统计多表联合查询数据条数用于库存列表分页
     * @param 
     * @return LogicWhAffstockVO
     */
    public Integer findForWareHouseStockCount(SearchConditions scs) throws DataAccessException;
    
    public List<LogicWarehouseInventoryDO> findWareHouseStockByMap(Map<String, Object> paramMap)throws DataAccessException;
    
    //退货入库单选择
    public List<LogicMaterialBackBillTypeSelVO> findSingleStockToBackSel(SearchConditions scs)throws DataAccessException;
    
    public Integer countSingleStockToBackSel(SearchConditions scs)throws DataAccessException;
    
    public Integer deleteWarehouseInventoryByMap(Map<String, Object> paramMap)throws SyBaseException;
    
    public List<LogicWarehouseEndMonthSumVO> findQueryEndMonthToSummary(SearchConditions scs)throws SyBaseException;
}